package com.amigo.online.consumer.video.service;

import java.util.List;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.amigo.online.common.core.response.Response;
import com.amigo.online.common.param.dto.video.LookVideoDto;
import com.amigo.online.common.param.dto.video.ShareVideoDto;
import com.amigo.online.common.param.dto.video.VideoCommentDto;
import com.amigo.online.common.param.dto.video.VideoDto;
import com.amigo.online.common.param.dto.video.VideoQueryDto;
import com.amigo.online.common.param.result.VideoInfo;

@FeignClient(name = "amigo-online-provider-video")
public interface VideoService {

	@RequestMapping(value = "/video/info/{id}", method = RequestMethod.GET)
	public ResponseEntity<Response> getVideoInfoById(@PathVariable("id") Long id);
	
	@RequestMapping(value = "/video/look", method = RequestMethod.POST)
	public ResponseEntity<Response> lookVideoById(@PathVariable("id") Long id,@PathVariable("lookTime") Long lookTime);
	
	@RequestMapping(value = "/video/look", method = RequestMethod.POST)
	public ResponseEntity<Response> lookVideoById(LookVideoDto dto);
	
	@RequestMapping(value = "/video/up/{id}", method = RequestMethod.POST)
	public ResponseEntity<Response> upVideoById(@PathVariable("id") Long id);
	
	@RequestMapping(value = "/video/up/{id}", method = RequestMethod.GET)
	public ResponseEntity<Response> videoUpStatus(@PathVariable("id") Long id);
	
	@RequestMapping(value = "/video/up/{id}", method = RequestMethod.DELETE)
	public ResponseEntity<Response> removeUpVideo(@PathVariable("id") Long id);
	
	@RequestMapping(value = "/video/comment/{id}", method = RequestMethod.POST)
	public ResponseEntity<Response> commentVideoById(@PathVariable("id") Long id,VideoCommentDto dto);

	//mark
	@RequestMapping(value = "/video/new", method = RequestMethod.POST)
	public ResponseEntity<Response> newUserVideo(VideoDto dto);

	
	@RequestMapping(value = "/video/my/videos/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> myVideos(@PathVariable("page")Integer page, @PathVariable("size")Integer size);

	@RequestMapping(value = "/video/my/looked/videos/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> myLokkerVideos(@PathVariable("page")Integer page, @PathVariable("size")Integer size);

	@RequestMapping(value = "/video/my/uped/videos/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> myUpedVideos(@PathVariable("page")Integer page,@PathVariable("size") Integer size);

	@RequestMapping(value = "/video/user/videos/{uid}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> getUserVideos(@PathVariable("uid")Long uid, @PathVariable("page")Integer page,@PathVariable("size") Integer size);

	@RequestMapping(value = "/video/user/looked/video/{uid}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> userLookVideoList(@PathVariable("uid")Long uid,@PathVariable("page") Integer page,@PathVariable("size") Integer size);

	@RequestMapping(value = "/video/user/uped/list/{uid}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> userUpVideoList(@PathVariable("uid")Long uid, @PathVariable("page")Integer page, @PathVariable("size") Integer size);
	
	@RequestMapping(value = "/video/recommended/{deviceId}/{page}/{size}/{idNine}/{idTen}", method = RequestMethod.GET)
	public ResponseEntity<Response> recommendedVideoList(@PathVariable("deviceId")String deviceId,@PathVariable("page") Integer page,@PathVariable("size")  Integer size,@PathVariable("idNine") Long idNine,@PathVariable("idTen") Long idTen);

	@RequestMapping(value = "/video/near/{longitude}/{latitude}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> nearVideoList(@PathVariable("longitude")String longitude, @PathVariable("latitude")String latitude, @PathVariable("page")Integer page, @PathVariable("size") Integer size);
	
	@RequestMapping(value = "/video/my/whoSawMe/{longitude}/{latitude}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> whoSawMe(@PathVariable("longitude")String longitude, @PathVariable("latitude")String latitude, @PathVariable("page")Integer page, @PathVariable("size") Integer size);

	@RequestMapping(value = "/video/my/collect/videos/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> myCollectVideos(@PathVariable("page")Integer page,@PathVariable("size") Integer size);

	@RequestMapping(value = "/video/collect/video/{videoid}", method = RequestMethod.GET)
	public ResponseEntity<Response> collectVideo(@PathVariable("videoid")Long videoid);

	@RequestMapping(value = "/video/cancel/collect/{videoid}", method = RequestMethod.GET)
	public ResponseEntity<Response> cancelCollect(@PathVariable("videoid")Long videoid);

	@RequestMapping(value = "/video/getAll", method = RequestMethod.GET)
	public ResponseEntity<Response> getAll();

	@RequestMapping(value = "/video/comments/{vid}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> getCommentList(@PathVariable("vid")Long vid,@PathVariable("page") Integer page,@PathVariable("size")  Integer size);

	@RequestMapping(value = "/video/concern", method = RequestMethod.POST)
	public List<VideoInfo> getVideoInfoByUserIdList(VideoQueryDto dto);

	@RequestMapping(value = "/video/delete/video/comment/{id}/{vid}", method = RequestMethod.GET)
	public ResponseEntity<Response> deleteComment(@PathVariable("id")Long id, @PathVariable("vid")Long vid);

	@RequestMapping(value = "/video/share", method = RequestMethod.POST)
	public ResponseEntity<Response> getDto(ShareVideoDto dto);

	@RequestMapping(value = "/video/delete/{id}", method = RequestMethod.DELETE)
	public ResponseEntity<Response> deleteVideoById(@PathVariable("id")Long id);

	@RequestMapping(value = "/video/lookNotLogined", method = RequestMethod.POST)
	public ResponseEntity<Response> lookNotLogined(LookVideoDto dto);

	@RequestMapping(value = "/video/commentsCount/{vid}",method = RequestMethod.GET)
	public ResponseEntity<Response> getCommentsCount(@PathVariable("vid")Long vid);

	@RequestMapping(value = "/video/sameMusicDetail/{musicId}",method = RequestMethod.GET)
	public ResponseEntity<Response> sameMusicDetail(@PathVariable Long musicId);
	
	@RequestMapping(value = "/video/getVideoInSameMusic/{musicId}/{page}/{size}", method = RequestMethod.GET)
	public ResponseEntity<Response> getVideoInSameMusic(@PathVariable Long musicId, @PathVariable Integer page,@PathVariable Integer size);

	@RequestMapping(value = "/video/recommended/v3/{deviceId}/{page}/{size}/{idNine}/{idTen}", method = RequestMethod.GET)
	public ResponseEntity<Response> recommendedVideoListv3(@PathVariable("deviceId")String deviceId,@PathVariable("page") Integer page,
			@PathVariable("size")  Integer size,@PathVariable("idNine") Long idNine,@PathVariable("idTen") Long idTen);

	@RequestMapping(value = "/video/v3/look", method = RequestMethod.POST)
	public ResponseEntity<Response> lookVideoByIdV3(LookVideoDto lookVideoDto);

}
